﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.UI;
using System.Web.UI.WebControls;
using System.Web.UI.HtmlControls;
namespace CAATS_Registration
{
    public partial class caats_step3 : System.Web.UI.Page
    {
        protected void Page_Load(object sender, EventArgs e)
        {
            //if (IsPostBack)
            //    return;
            dataRecord.Instance()._infoCnt = 0;
            Int32 nCnt;
            nCnt = Convert.ToInt32(dataRecord.Instance()._strMemberCnt);
            HtmlTableRow[] MemberInfo = new HtmlTableRow[5];
            MemberInfo[0] = MemberInfo1;
            MemberInfo[1] = MemberInfo2;
            MemberInfo[2] = MemberInfo3;
            MemberInfo[3] = MemberInfo4;
            MemberInfo[4] = MemberInfo5;

            for (Int32 i = 0; i < 5; i++)
            {
                MemberInfo[i].Visible = false;
            }
            for(Int32 i=0; i<nCnt; i++ )
            {
                MemberInfo[i].Visible = true;
            }

        }

        protected void Back_Click(object sender, EventArgs e)
        {
            Server.Transfer("caats_step2.aspx?name=step2", true); 
        }

        protected void Next_Click(object sender, EventArgs e)
        {
            Int32 nCnt;
            nCnt = Convert.ToInt32(dataRecord.Instance()._strMemberCnt);
            //if ( 1 == nCnt )
            //{
            //    Response.Write("<script language=''>MemberInfo1.location.reload();</script>");

            //}

            //for (int i = 0; i < nCnt; i++)
            //{
            //    if (dataRecord.Instance().m_listInfos[i].needReInput())
            //    {
            //        Response.Write(" <script laguage= 'javascript'> alert( 'Please complete the information with a red asterisk (*) '); </script> ");
            //        return;
            //    }
            //}
            Server.Transfer("caats_step4.aspx?name=step4", true); 
        }

        protected void ClearYourSelection_Click(object sender, EventArgs e)
        {

        } 
    }
}
